<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" type="text/css"href="<c:url value="/css/themes/default/easyui.css"/>">
<link rel="stylesheet" type="text/css" href="<c:url value="/css/themes/icon.css"/>">
<link rel="stylesheet" type="text/css" href="<c:url value="/css/themes/hwc_login_style.css"/>">
<script type="text/javascript" src="<c:url value="/js/jquery.min.js"/>"></script>
<script type="text/javascript" src="<c:url value="/js/jquery-3.1.0.js"/>"></script>
<script type="text/javascript" src="<c:url value="/js/jquery.easyui.min.js"/>"></script>
<script type="text/javascript" src="<c:url value="/js/easyui-lang-zh_CN.js"/>"></script>

<title>欢迎使用医院管理系统</title>
</head>
<body>
<!-- 文字区不需要请连css部分代码一并删除 -->
<h3 id="box">
<div id="title">
<b>中心医院欢迎您</b>
</div>
<div id="context">
	<script type="text/javascript">
	$(function(){
		$("#hwc_login_submit").click(function(){
			var accountLen = $("#account").val().length;
			var passwordLen = $("#password").val().length;
			
			if(accountLen < 7 || accountLen > 20){
				
				$.messager.alert("提示","员工账号必须在7—20个字符之间！");
				return false;
				
			}else if(passwordLen == 0){
				$.messager.alert("提示","密码不能为空！");
				return false;
			}	  
		});	
	});
	</script>
	<script>
			$.extend($.fn.textbox.methods, {
				addClearBtn : function(jq, iconCls) {
					return jq.each(function() {
							var t = $(this);
							var opts = t.textbox('options');
							opts.icons = opts.icons || [];
	
							opts.icons.unshift({
								iconCls : iconCls,
							handler : function(e) {
							//点击图标后图标消失并且清除文本内容
							$(e.data.target).textbox('clear').textbox('textbox').focus();
							$(this).css('visibility', 'hidden');
				}});
				t.textbox();
				//alert(t.textbox('getText'));
				if (!t.textbox('getText')) {
					//隐藏输入框中的图标
					t.textbox('getIcon', 0).css('visibility','hidden');
				}
				t.textbox('textbox').bind('keyup', function() {
				var icon = t.textbox('getIcon', 0);
				if ($(this).val()) {
					icon.css('visibility', 'visible');
				} else {
					icon.css('visibility', 'hidden');
				}});
				});
			}});
		$(function() {
			$('#account').textbox('addClearBtn', 'icon-clear');
			$('#password').textbox('addClearBtn', 'icon-clear');
	
		});
	</script>
	
	<form  id="hwc-loginform" action="yzr_login" method="post">
		账号：<input  id="account" name="account" class="easyui-textbox" data-options="prompt:'请输入账号',validType:'length[7,20]',required:true"><br><br> 
		密码：<input  id="password"  name="password" class="easyui-passwordbox" data-options="prompt:'请输入密码',required:true">
		<input id="hwc_login_submit" type="submit" value="登录"> 
	</form>
</div>
<div id="bottombox"></div>
</h1>

<!-- 你可以添加个多“.slideshow-image”项目, 记得修改CSS -->

	<div class="slideshow">
	
			<div class="slideshow-image"	style="background-image: url('css/themes/img/hwc_lunbo1.jpg')"></div>
			<div class="slideshow-image"	style="background-image: url('css/themes/img/hwc_lunbo2.jpg')"></div>
			<div class="slideshow-image"	style="background-image: url('css/themes/img/hwc_lunbo3.jpg')"></div>
			<div class="slideshow-image"	style="background-image: url('css/themes/img/hwc_lunbo4.jpg')"></div>
	</div>

</body>
</html>